import observe from "./observe";
function defineReactiveData(data,key,value){
    observe(value);
    Object.defineProperty (data,key,{
        get(){
            // console.log('获取响应数据',value)
            return value;
        },
        set(newValue){
            // console.log('新数据')
            if(newValue === value) return;
            observe(newValue);
            value = newValue;

        }
})
}
export default defineReactiveData;